@rem Description: filter_agent build script, Platform:ARM64
@echo off


echo --------------------------init visual studio env--------------------------
set VCVARSAMD64_ARM64_CMD="C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Auxiliary\Build\vcvarsamd64_arm64.bat"
set VCVARSAMD64_X64_CMD="C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Auxiliary\Build\vcvars64.bat"

echo ----------------------------build filter agent----------------------------

cd %~dp0\filter_agent
md build
cd build
cmake -G "Visual Studio 16 2019" -A ARM64 ..
cmake --build . --config Release

if %ERRORLEVEL% EQU 0 ( goto end ) else ( goto error )

:end
echo "clean up."
echo "compile success."
exit /b 0

:error
echo "compile failed!"
exit /b 1
